From 46d1db8502cc67a2c90992b59015e6bbcca7bcf7 Mon Sep 17 00:00:00 2001 From: robertl Date: Tue, 14 Oct 2008 15:52:52 +0000 Subject: [PATCH] Add error message to style reader when missing comma after token. git-svn-id: http://gpsbabel.googlecode.com/svn/trunk@3555 f51c46e8-681c-474f-0cfe-069cfd0219fb --- gpsbabel/csv_util.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gpsbabel/csv_util.c b/gpsbabel/csv_util.c index 200db154e..45b22b9b4 100644 --- a/gpsbabel/csv_util.c +++ b/gpsbabel/csv_util.c @@ -929,6 +929,10 @@ xcsv_parse_val(const char *s, waypoint *wpt, const field_map_t *fmp) char *enclosure = ""; geocache_data *gc_data = NULL; + if (!fmp->printfc) { + fatal(MYNAME ": xcsv style '%s' is missing format specifier", fmp->key); + } + if (0 == strcmp(fmp->printfc, "\"%s\"")) { enclosure = "\""; } -- 2.30.2